/**
 * 
 */
package com.jquery.ui.tags.beans.script;

import java.util.Map;

import com.jquery.ui.core.bean.UIBean;
import com.jquery.ui.dictionary.IDlgTypeEnum;
import com.jquery.ui.uitls.StringUtils;

/**
 * @author linyajun
 * 
 * @date	2013-9-24
 * @description   
 */
public class DialogScriptUI extends UIBean {

	/**
	 * 
	 */
	private static final long serialVersionUID = -7075309708945842131L;

	private String title;
	private String width;
	private String height;
	private Boolean modal=false;
	private IDlgTypeEnum dialogType;
	private String src;
	/**
	 * @return the modal
	 */
	public Boolean getModal() {
		return modal;
	}
	/**
	 * @param modal the modal to set
	 */
	public void setModal(Boolean modal) {
		this.modal = modal;
	}
	@Override
	public void putAttribute(Map<String, Object> attribute) {
		if (StringUtils.isNotEmpty(title)) {
			attribute.put("title", title);
		}
		if (StringUtils.isNotEmpty(width)) {
			attribute.put("width", width);
		}
		if (StringUtils.isNotEmpty(height)) {
			attribute.put("height", height);
		}
				if (StringUtils.isNotEmpty(src)) {
						attribute.put("src", src);
					}

		attribute.put("modal", modal);
		attribute.put("dialogType", dialogType);

	}
	/**
	 * @return the title
	 */
	public String getTitle() {
		return title;
	}
	/**
	 * @param title the title to set
	 */
	public void setTitle(String title) {
		this.title = title;
	}
	/**
	 * @return the width
	 */
	public String getWidth() {
		return width;
	}
	/**
	 * @param width the width to set
	 */
	public void setWidth(String width) {
		this.width = width;
	}
	/**
	 * @return the height
	 */
	public String getHeight() {
		return height;
	}
	/**
	 * @param height the height to set
	 */
	public void setHeight(String height) {
		this.height = height;
	}
	/**
	 * @return the dialogType
	 */
	public IDlgTypeEnum getDialogType() {
		return dialogType;
	}
	/**
	 * @param dialogType the dialogType to set
	 */
	public void setDialogType(IDlgTypeEnum dialogType) {
		this.dialogType = dialogType;
	}
	/**
	 * @return the src
	 */
	public String getSrc() {
		return src;
	}
	/**
	 * @param src the src to set
	 */
	public void setSrc(String src) {
		this.src = src;
	}
	
	

}
